﻿using System;
using OigSync.Infrastructure.Api;

namespace OigSync.Domain.Api {
    public class GetOrdersApiSetting : IApiSetting {
        public Boolean IncludeFinalValueFee { get; set; }

        public int EntriesPerPage { get; set; }

        public DateTime TimeFrom { get; set; }

        public DateTime TimeTo { get; set; }

        public int PageNumber { get; set; }

        public int Timeout { get; set; }

        public int RetryDelayTime { get; set; }

        public int RetryMaximumRetries { get; set; }

        public GetOrdersApiSetting() {
            this.EntriesPerPage = 25;
            this.IncludeFinalValueFee = true;
            this.Timeout = 12000;
            this.RetryDelayTime = 1000;
            this.RetryMaximumRetries = 5;
        }

        public GetOrdersApiSetting(DateTime from, DateTime to, int pageNumber) : this()
        {
            this.TimeFrom = from;
            this.TimeTo = to;
            this.PageNumber = pageNumber;
        }
    }
}
